<?php


namespace app\admin\controller\member2;


use app\common\controller\Adminbase;
use think\Db;

class Member2 extends Adminbase
{
    protected function initialize()
    {
        parent::initialize();
    }
    public function index(){
        if ($this->request->isAjax()) {
            list($page, $limit, $where) = $this->buildTableParames();
            $_list=Db::name('member')
                ->where($where)
                ->page($page,$limit)
                ->select();
            $total=Db::name('member')
                ->where($where)
                ->count();
            $result = ["code" => 0, "count" => $total, "data" => $_list];
            return json($result);
        }
        return $this->fetch();
    }
}